<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <link rel="stylesheet" type="text/css" href="{% static '/css/index.css' %}"/>
    <script src="{% static '/js/jquery-3.2.1.min.js' %}"></script>
    <title>密码找回</title>
    <script>
        $(function (){
            $("#btn").click(function (){
                let oldpassword = $("#oldpassword").val()
                if (oldpassword == "" || oldpassword == undefined){
                    alert("原密码不能为空");
                    return;
                }
                let onepassword = $("#onepassword").val()
                if (onepassword == "" || onepassword == undefined){
                    alert("新密码不能为空");
                    return;
                }
                let twopassword = $("#twopassword").val()
                if (twopassword == "" || twopassword == undefined){
                    alert("新密码不能为空");
                    return;
                }
                $("#myform").submit();
            })
        })
    </script>
</head>
<body>
    <header>
    	<div class="lf">
    		<a class="home" href="{% url 'index' %}">系统首页</a>
    		<!-- <a href="bbs.html">论坛</a> -->
    		<a href="upload.html">上传资料</a>
    	</div>
    	<div id="search">
    		<input type="text" name="name" 
    			placeholder="请输入要搜索的资源" autocomplete="off"/><a class="search btn">搜索</a>
    	</div>
    	
    	<div class="rf">
    		<a href="{% url 'auth:userlogin' %}">登录/注册</a>
    		<a class="info" href="{% url 'auth:userpersonal' %}">个人中心</a>
    		<a class="cols" href="shoucang.html">收藏</a>
    		<a class="exit" href="{% url 'auth:userlogout' %}">退出登录</a>
    	</div>
    </header>
	<article>
		<!-- 网站主体 -->
		<div id="main">
			<section class="ct">
				<div class="upload">
					<h1>修改密码</h1>
					<form action="{% url 'auth:usermodifypass' %}" id="myform" method="post">
						<p>
							<label>旧密码：</label>
							<input id="oldpassword" class="upt" type="password" name="password" value="" placeholder="请输入原密码"/>
							<em></em>
						</p>
						<p>
							<label>新密码：</label>
							<input id="onepassword" class="upt" type="password" name="onepassword" value="" placeholder="请输入新密码"/>
							<em></em>
							<span class="source-tag-msg">密码长度为6~20</span>
						</p>
						<p>
							<label>确认密码：</label>
							<input id="twopassword" class="upt" type="password" name="twopassword" value="" placeholder="请再次输入新密码"/>
							<em></em>
							<span class="source-tag-msg">两次输入的密码必须保持一致</span>
						</p>
						
						<p><label class="btn"><input type="button" id="btn" class="btn" value="确认修改" /></label></p>
					</form>
				</div>
			</section>	
		</div>
	</article>
	<footer>
		<p class="decro">本站所有资源信息均由网友上传,本站只是为了推广资源让更多读者下载,使用。如涉侵权，请联系管理员</p>
		<p class="cr">Copyright © 2021-2025 <span class="site">爱下载资源分享平台</span> All Rights Reserved.</p>
		<p class="num">沪ICP备14048333号</p>
	</footer>
</body>

</html>